class CreateEquipment < ActiveRecord::Migration
  def self.up
	create_table :equipment, :primary_key => :id do |t|
		t.string	:uniqueid
		t.string	:model
		t.string	:brand
		t.string	:size
		t.string	:weekend_cost
		t.string	:weekday_cost
		t.text		:description
		t.string	:category
		t.datetime	:date_added
		t.datetime	:date_retired
		t.integer	:customer_id
		t.datetime	:out_date
		t.datetime	:in_date
		t.integer	:rental_id
		t.integer	:package_id
		t.boolean	:retired,	:default => 0
		t.text		:pros
		t.text		:cons
		t.text		:comments
	end
	Equipment.create :uniqueid => 1,
	  :model => "Cam",
	  :size => "3",
	  :weekend_cost => "10",
	  :weekday_cost => "12",
	  :description => "Used for climbing",
	  :date_added => Date.new(Time.now.year,Time.now.month,Time.now.day)
	Equipment.create :uniqueid => 2,
	  :model => "Cam",
	  :size => "2",
	  :weekend_cost => "10",
	  :weekday_cost => "12",
	  :description => "Used for climbing...or something",
	  :date_added => Date.new(Time.now.year,Time.now.month,Time.now.day)
	Equipment.create :uniqueid => 3,
	  :model => "Paddle",
	  :size => "72",
	  :weekend_cost => "3",
	  :weekday_cost => "5",
	  :description => "Used for rafting",
	  :date_added => Date.new(Time.now.year,Time.now.month,Time.now.day)
  end

  def self.down
  	drop_table :equipment
  end
end

